home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Gold Medal Software 2
/
Gold Medal Software Volume 2 (Gold Medal) (1994).iso
/
os2
/
cenvi2.arj
/
CBPRINT.CMD
< prev
next >
Wrap
OS/2 REXX Batch file
|
1993-11-17
|
643b
|
20 lines
EXTPROC CEnvi
/********************************************************************
*** CBPrint.cmd - Print contents of the clipboard to the printer ***
********************************************************************/
#include <ClipBrd.lib>
ClipText = GetClipboardData(CF_TEXT);
if ( ClipText ) {
printf("Have clipboard text\n");
fp = fopen("\\DEV\\PRN","wt");
if ( fp ) {
fwrite(ClipText,strlen(ClipText),fp);
fclose(fp);
printf("Clipboard text has been sent to the printer.\n");
} else
printf("Error opening printer.\n");
} else
printf("No text data in the clipboard.\n");